#include "Portal.h"

Portal::Portal()
{
}

Portal::Portal(const std::string& destLevel, const sf::Vector2f& sourcePos, const sf::Vector2f& destPos)
: destLevel(destLevel)
, sourcePos(sourcePos)
, destPos(destPos)
{
}

bool operator==(const Portal& lhs, const Portal& rhs)
{
    return &lhs == &rhs || lhs.sourcePos == rhs.sourcePos ||
        lhs.destPos == rhs.destPos || lhs.destLevel == rhs.destLevel;
}

bool operator!=(const Portal& lhs, const Portal& rhs)
{
    return !(lhs == rhs);
}

//void Portal::readElement(ticpp::Element* element)
//{
//}
//
//void Portal::writeElement(ticpp::Element* element) const
//{
//}

const std::string& Portal::getDestLevel() const
{
	return destLevel;
}

const sf::Vector2f& Portal::getSourcePos() const
{
	return sourcePos;
}

const sf::Vector2f& Portal::getDestPos() const
{
	return destPos;
}